<?php

namespace App\Http\Controllers;

use Illuminate\Http\Request;

use App\Http\Requests;
use App\Http\Controllers\Controller;
use DB;

class UserController extends Controller
{
   
    public function user_list(){

        $users=DB::table('Users')->get();
        $count=DB::table('users')->count();
        $u=[
            'users'=>$users,
            'count'=>$count,
        ];
        return view('Admin.user_list',$u);
    }


    public function del($id){
        // echo $id;
        // var_dump(DB::table('Users')->where('id',$id)->delete());
        $req=DB::table('Users')->where('id',$id)->delete();
        if($req){
            return redirect('/Admin/user_list');
        }else{
            echo 'false';
        };
    }


    public function member_Grading(){
//        echo "member_Grading";
        return view('Admin/member_Grading');
    }
    public function integration(){
//        echo "integration";
        return view('Admin/integration');
    }

}
